home *** CD-ROM | disk | FTP | other *** search
- #pragma .h #import <objc/Object.h>
- #pragma .h #import <appkit/Application.h>
- #import "NObject.h"
- #import "MenuManager.h"
-
- /**
- ** NObjects are just like Objects,
- ** except that they do not kill off
- ** the application when they receive
- ** a message they can't understand.
- ** Instead, they pop up an alert panel,
- ** allowing the user to either continue,
- ** or abort.
- **/
-
- @implementation NObject: Object
- {
- }
-
- - doesNotRecognize: (SEL)aSelector ;
- { int rval ;
- rval = NXRunAlertPanel("Nu",
- "Nu Error:\n%s doesNotRecognize: %s","Continue","Abort Nu",
- NULL, [self name], sel_getName(aSelector)) ;
- if(rval == 1) // i.e. continue
- return self ;
- [self error: "Nu aborted by user\n"] ;
- return self ;
- }
-
-
- @end